package com.cloudbroker.bcs.common.context;

public class BizDataContext {
    
    private static final String NAMESPACE = BizDataContext.class.getName();
    
    private static final String KEY_ACCESS_TOKEN = NAMESPACE + ".access_token";
    
    private static final String KEY_BIZ_SERVICE_NAME = NAMESPACE + ".bizServiceName";
    
    public static final String KEY_USERCENTER_ID = NAMESPACE + ".userCenterId";
    
    public static Long getUserCenterId() {
        return (Long) BizDataContext.get(KEY_USERCENTER_ID);
    }
    
    public static void setUserCenterId(Long userCenterId) {
        BizDataContext.set(KEY_USERCENTER_ID, userCenterId);
    }
    
    public static String getAccess_token() {
        return (String) get(KEY_ACCESS_TOKEN);
    }
    
    public static void setAccess_token(String access_token) {
        set(KEY_ACCESS_TOKEN, access_token);
    }
    
    public static String removeAccess_token() {
        return (String) remove(KEY_ACCESS_TOKEN);
    }
    
    public static String getBizServiceName() {
        return (String) get(KEY_BIZ_SERVICE_NAME);
    }
    
    public static void setBizServiceName(String bizServiceName) {
        set(KEY_BIZ_SERVICE_NAME, bizServiceName);
    }
    
    public static String removeBizServiceName() {
        return (String) remove(KEY_BIZ_SERVICE_NAME);
    }
    
    public static Object get(String key) {
        return DataContext.get(key);
    }
    
    public static Object set(String key, Object value) {
        return DataContext.set(key, value);
    }
    
    public static Object remove(String key) {
        return DataContext.remove(key);
    }
    
    public static void clear() {
        DataContext.clear();
    }
    
}
